home *** CD-ROM | disk | FTP | other *** search
/ Scene Storm / Scene Storm - Volume 1.iso / coding / c / unix / src / fifo.h < prev    next >
C/C++ Source or Header  |  1992-07-19  |  1KB  |  42 lines

  1.  
  2. /*
  3.  *  FIFO.H
  4.  *
  5.  *  PUBLIC FIFO STRUCTURES AND DEFINES
  6.  */
  7.  
  8. #ifndef LIBRARIES_FIFO_H
  9. #define LIBRARIES_FIFO_H
  10.  
  11. #define FIFONAME    "fifo.library"
  12.  
  13. #define FIFOF_READ      0x00000100L      /*  intend to read from fifo      */
  14. #define FIFOF_WRITE      0x00000200L      /*  intend to write to fifo      */
  15. #define FIFOF_RESERVED      0xFFFF0000L      /*  reserved for internal use   */
  16. #define FIFOF_NORMAL      0x00000400L      /*  request blocking/sig support*/
  17. #define FIFOF_NBIO      0x00000800L      /*  non-blocking IO          */
  18.  
  19. #define FIFOF_KEEPIFD      0x00002000L      /*  keep fifo alive if data pending */
  20. #define FIFOF_EOF      0x00004000L      /*  EOF on close              */
  21. #define FIFOF_RREQUIRED   0x00008000L      /*  reader required to exist      */
  22.  
  23. #define FREQ_RPEND    1
  24. #define FREQ_WAVAIL    2
  25. #define FREQ_ABORT    3
  26.  
  27. typedef void *FifoHan;              /*  returned by OpenFifo()  */
  28.  
  29. #ifndef IN_LIBRARY
  30.  
  31. FifoHan OpenFifo(char *, long, long);
  32. void CloseFifo(FifoHan, long);
  33. long ReadFifo(FifoHan, char **, long);
  34. long WriteFifo(FifoHan, char *, long);
  35. void RequestFifo(FifoHan, struct Message *, long);
  36. long BufSizeFifo(FifoHan);
  37.  
  38. #endif
  39.  
  40. #endif
  41.  
  42.